package com.wynn.serviceFeign;

import com.wynn.pojo.User;
import com.wynn.pojo.Result;
import org.springframework.cloud.openfeign.FeignClient;


import org.springframework.web.bind.annotation.*;

import java.util.List;
import java.util.Map;


@FeignClient("serviceProviderBase")
public interface UserClient {

    @GetMapping("user/findByUser")
    Result findByUser(@RequestParam(value = "login_name") String login_name, @RequestParam(value = "ip") String ip);

    @GetMapping("user/getByName")
    User getByName(@RequestParam(value = "username") String username);

    @GetMapping("user/getUserAuthorityInfo")
    String getUserAuthorityInfo(@RequestParam(value = "username") String username);

    @GetMapping("user/findByPerm")
    List<String> findByPerm(@RequestParam(value = "name") String name);

    @PostMapping("user/addNotice")
    void addNotice(Map<String, String> notices);

    @GetMapping("user/selectNotice")
    List<Map<String, String>> selectNotice();
}
